<?php

namespace app\controllers\admin\uni\system;

use app\controllers\admin\base\AdminController;
use app\models\system\SetCertBg as Model;

class SetCertBgController extends AdminController
{
    public function actionFetch()
    {
        $model = Model::getLastOne();

        return $this->success($model);
    }

    public function actionSave()
    {
        $images = $this->post('image');

        if (Model::saveData($images)) {

            return $this->success();
        }

        return $this->fail();
    }

}